package btp.Calendars;

public class JulianDay {
	public static final double EPOCH =  (GregorianCalendar.getRDFromGregorian(-4713, GregorianCalendar.NOVEMBER, 24)+0.5); 

	double julianDay;

	
	public JulianDay(double julianDay) {
		super();
		this.julianDay = julianDay;
	}
	

	public final double getJulianDay() {
		return julianDay;
	}


	public final void setJulianDay(double julianDay) {
		this.julianDay = julianDay;
	}


	public double getRDFromJDay(){
		return (julianDay+EPOCH);	
	}
	
	public static JulianDay getJDayFromRD(long rd){
		return new JulianDay(rd-EPOCH);
	}
}
